package com.chenhao.springcloud.chenhaodesignservice.pattern.creational.singleton;

/**
 * Description:静态内部类
 *
 * @author chenhao
 * @date 2020/12/17 11:37
 */
public class StaticInnerClassSingleton {
    private static class InnerClass{
        private static StaticInnerClassSingleton staticInnerClassSingleton;
    }

    public static  StaticInnerClassSingleton getInstance(){
        return InnerClass.staticInnerClassSingleton;
    }

    private StaticInnerClassSingleton(){

    }
}
